package com.fyk.mapper;

import com.fyk.entity.Book;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @Author qazws
 * @Date 2022/8/19 9:24
 * @Version 1.0
 */

@Repository
public interface BookMapper {

    List<Book> selectBook(Book book);

    int insertBook(Book book);

    int updateBook(Book book);

    int deleteBook(Book book);

    List<Book> selectBookByUserId(Integer userId);

    List<Book> selectBookByBookWriterOrBookName(@Param("bookName") String bookName,@Param("bookWriter") String bookWriter,@Param("userId") Integer userId);

    Book selectBookByBookId(Integer bookId);

    int delAllBook(List<String> lists);
}
